﻿Imports StructureMap

Public Class IoCControllerFactory
    Inherits DefaultControllerFactory

    Protected Overrides Function GetControllerInstance(ByVal controllerType As System.Type) As System.Web.Mvc.IController

        Try
            Return ObjectFactory.GetInstance(controllerType)
        Catch ex As Exception
            System.Diagnostics.Debug.WriteLine(ObjectFactory.WhatDoIHave())
            Throw
        End Try

    End Function

End Class
